package com.amigo.online.consumer.common.service;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

import com.amigo.online.common.core.response.Response;
import com.amigo.online.common.param.dto.video.AreaDto;

@FeignClient(name = "amigo-online-provider-common")
public interface CommonService {

	@RequestMapping(value = "/common/global/config", method = RequestMethod.GET)
	public ResponseEntity<Response> getGlobalConfig();
	
	@RequestMapping(value = "/common/area/list/{lang}/{pid}/{page}/{size}", method = RequestMethod.GET)
	public ResponseEntity<Response> getAreaList(@PathVariable("lang") String lang,@PathVariable("pid") Integer pid,@PathVariable("page") Integer page,@PathVariable("size") Integer size);
	
	@RequestMapping(value = "/common/area/name/{lang}/{id}", method = RequestMethod.GET)
	public ResponseEntity<Response> getAreaName(@PathVariable("lang") String lang,@PathVariable("id") Integer id);

	@RequestMapping(value = "/common/global/config/md5", method = RequestMethod.GET)
	public ResponseEntity<Response> getGlobalMd5();

	@RequestMapping(value = "/common/linkageQuery", method = RequestMethod.POST)
	public ResponseEntity<Response> linkageQuery(AreaDto dto);
}
